<template>
  <div>
    <el-form ref="searchForm" :rules="searchFormRules" :model="searchForm">
      <el-form-item prop="enableField" label="是否启用" >
        <el-select v-model="searchForm.enableField" placeholder="状态" style=" width: 120px" allowClear>
          <el-option value="true">启用</el-option>
          <el-option value="false">禁用</el-option>
        </el-select>
      </el-form-item>
      <el-form-item prop="affectsField" label="影响类型" >
        <el-select v-model="searchForm.affectsField" placeholder="请选择" style=" width: 200px" allowClear>
          <el-option v-for="item in searchFormRules" :key="item.name" :value="item.name">{{item.label}}</el-option>
        </el-select>
      </el-form-item>
      <el-form-item prop="search" label="模糊查询" >
        <el-input v-model="searchForm.search" placeholder="请输入模糊查询" clearable />
      </el-form-item>
      <el-button on-click="searchRules">

      </el-button>
    </el-form>
  </div>
</template>

<script>
import {getVulBasic} from "@/api/my/loophole/vul";

export default {
  name: "searchForm",
  data() {
    return {
      searchForm:{
        enableField: '',
        affectsField: '',
        search: '',
      },
      searchFormRules : [
      ]
    }
  },
  created() {
    this.setVulBasic()
  },
  methods: {
    setVulBasic(){
      this.searchFormRules = JSON.parse(window.localStorage.getItem("vul")).ModuleAffects
    }
  },
}
</script>

<style scoped>

</style>